module top_tb;
    reg clk = 1, rst_n = 0;;
    Counter7 c7;
    initial begin
        c7 = new();
        for(int i=0; i<10; i++)begin
            @(posedge clk);
            c7.count();
            $display("%s %0d: c7.cnt = %0d", `__FILE__, `__LINE__,  c7.get());
        end
        @(posedge clk);
        c7.reset();
        @(posedge clk);
        c7.load(64);
        for(int i=0; i<10; i++)begin
            @(posedge clk);
            c7.count();
            $display("%s %0d: c7.cnt = %0d", `__FILE__, `__LINE__,  c7.get());
        end
        repeat(10)@(posedge clk);
        $finish;
    end

    initial begin
        while(1)begin
            #5;
            clk = ~clk;
        end
    end
    initial begin
        #101;
        rst_n = 1;
    end
    initial begin
        $fsdbDumpvars(0, top_tb);
        $fsdbDumpMDA(0, top_tb);
        $fsdbDumpSVA;
    end

endmodule
